package com.example.demo.game.plane;


import com.example.demo.entity.User;

import java.util.ArrayList;
import java.util.List;

// 飞机类
public class Pot {
    Vec pos;
    Vec speed;
    Vec rot;
    double mass;
    User user;
    List<Integer> visited;

    public Pot(User user) {
        this.user = user;
        mass = 1;
        pos = new Vec(0, 0);
        speed = new Vec(0, 0);
        rot = new Vec(0, 0);
        visited = new ArrayList<>();
        visited.add(0);
    }

    public Pot(Vec pos, Vec rot, User user) {
        this.pos = pos;
        speed = new Vec(0, 0);
        this.rot = rot;
        mass = 1;
        this.user = user;
        visited = new ArrayList<>();
        visited.add(0);
    }

    public double dis(Pot pot) {
        return this.pos.dis(pot.pos);
    }

    public double dis(Vec pos) {
        return this.pos.dis(pos);
    }

}
